﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Net;
using System.Net.Http;
using System.Web.Http;
using Gecko.Services;

namespace Gecko.Controllers
{
    public class WaterLeakHistoryController : ApiController
    {
        // GET api/waterleakhistory
        public object Get(int id)
        {
            using (var waterLeakService = new WaterLeakService())
            {
                var result = waterLeakService.GetWaterLeakHistory(id);

                return new
                           {
                               Data = result
                           };
            }
        }

        
        // POST api/waterleakhistory
        public void Post([FromBody]string value)
        {
        }

        // PUT api/waterleakhistory/5
        public void Put(int id, [FromBody]string value)
        {
        }

        // DELETE api/waterleakhistory/5
        public void Delete(int id)
        {
        }
    }
}
